// 开发环境接口配置
// JAVA Boot版本对应后端接口地址
// JAVA Cloud对应网关地址
// const APIURl = process.env.NODE_ENV === "development" ? '/dev' : window.config.VUE_APP_BASE_API
let proConfig = {
  ...window.config
}

// const APIURl = 'http://192.168.1.158:30000'
const APIURl = "http://127.0.0.1:30000/";
// http://127.0.0.1:30000/

console.log(' process.env.NODE_ENV', process.env.NODE_ENV, process.env.VUE_APP_BASE_API)
export default {
  APIURl: APIURl,
  timeout: process.env.NODE_ENV === "development" ? 1000000 : 1000000,
  WebSocketUrl: process.env.NODE_ENV === "development" ?
    window.config.VUE_APP_BASE_API.replace("http", "ws") + "/api/message/websocket" :
    proConfig.VUE_APP_BASE_WSS + "/api/message/websocket",
  comUploadUrl: process.env.NODE_ENV === "development" ?
    process.env.VUE_APP_BASE_API + '/api/file/Uploader' : proConfig.VUE_APP_BASE_API + "/api/file/Uploader",
  comUrl: process.env.NODE_ENV === "development" ?
    process.env.VUE_APP_BASE_API : proConfig.VUE_APP_BASE_API,
  // 本地文件预览
  filePreviewServer: process.env.NODE_ENV === "development" ?
    "http://localhost:30090" :
    proConfig.VUE_APP_BASE_API + "/FileServer",
  // 大屏应用前端路径
  dataV: process.env.NODE_ENV === "development" ?
    "http://localhost:8100/DataV" :
    proConfig.VUE_APP_BASE_API + "/DataV",
  // 数据报表接口-java boot
  reportServer: process.env.NODE_ENV === "development" ?
    "http://localhost:30007" :
    proConfig.VUE_APP_BASE_API + "/ReportServer",
  // 数据报表接口-java cloud
  // reportServer: process.env.NODE_ENV === 'development' ? 'http://localhost:30000' : process.env.VUE_APP_BASE_API,
  // 报表前端
  report: process.env.NODE_ENV === "development" ?
    "http://localhost:8200" :
    proConfig.VUE_APP_BASE_URL + "/Report",



  localUrl: "http://127.0.0.1:3000",
  serverFrontUrl: `${proConfig.allIp}/jsbos-logistics-web`,
  serverOnlineUrl: `http://${proConfig.allIp}/jsbos_logistics_serve`,
  previewLocalUrl: "http://127.0.0.1:30090/",
  previewServerUrl: `${proConfig.allIp}/FileServer/`,
};
